The present invention relates generally to the field of video processing, and more particularly to storing a video and playing the video.
Video provides an electronic medium for recording, copying, playback, broadcasting, and displaying moving visual media. Digital video represents the data for moving visual images in the form of encoded digital data that is discontinuous. Digital video utilizes a video coding format (e.g., video compression format) that is a content representation format for storage or transmission of digital video content (e.g., data file, bit stream, etc.). Video compression utilizes coding techniques to reduce redundancy in video data such as a series of still image frames. The sequence of the frames contain spatial and temporal redundancies that video compression algorithms attempt to eliminate or code in a smaller size. One of the most powerful techniques for compressing video is inter-frame compression. Inter-frame compression uses one or more earlier or later frames in a sequence to compress the current frame while intra-frame compression only uses the current frame (i.e. image compression).
With inter frame prediction, an inter coded frame is divided into blocks known as macro blocks. Rather than encoding the raw pixel values for each block, an encoder searches within a previously encoded frame, or reference frame for a block similar to the one being encoding. When the encoder locates a similar block, the current block is encoded by a motion vector, which points to the position of the matching block at the reference frame and calculates the differences (e.g., prediction error) between the two blocks that need to be transformed. The prediction error is sent to a decoder in order to recover the raw pixels of the encoded block during viewing. When a suitable match is not found, or when a possible reference frame is also encoded using inter frame prediction, in order to synchronize the video stream and reduce the chances of propagating errors in subsequent blocks, an I-frame is used which is intra coded and does not need additional information to be decoded.